import requests
from bs4 import BeautifulSoup


url = 'http://quotes.toscrape.com/'
response = requests.get(url)
print(response.text)
a = BeautifulSoup(response.text, 'html.parser')
results = a.find_all('span', attrs={'class': 'text','itemprop': 'text'})
# for result in results:
#     print(result.text)

authors = a.find_all('small', attrs={'class': 'author','itemprop': 'author'})
# for author in authors:
#     print(author.text)


tagses = a.find_all('div', attrs={'class': 'tags'})
# for tags in tagses:
#     print(tags.text.split())

datas = []
for i in range(0,len(authors)):
    datas.append({
        'text': results[i].text,
        'author': authors[i].text,
        'tags': tagses[i].text.split()[1:],
    })
for data in datas:
    print(data)
